# -*-coding:utf-8-*-
import os
from public.common.readconfig import ReadConfig

config_file_path = os.path.dirname(os.path.realpath(__file__))
config_params = ReadConfig(os.path.join(config_file_path, "config.ini"))

# 获取浏览器
config_driver = config_params.getValue("projectConfig", "driver")

# 获取项目
project_path = config_params.getValue("projectConfig", "project")

# 测试报告路径
report_path = os.path.join(project_path, "report")

# log日志的路径
log_path = os.path.join(project_path, "log")

# 测试数据的路径
test_data_path = os.path.join(project_path, "data", "testdata")

# 登录csv_path
login_csv_path = os.path.join(project_path, "data", "testdata", "login_data.csv")

# 用户制作-新增csv_path
add_user_path = os.path.join(project_path, "data", "testdata", "add_user.csv")

# 用户制作-搜索
production_search_path = os.path.join(project_path,"data", "testdata", "production_search.csv")

# 测试用例的路径
test_case_path = os.path.join(project_path, "testcase")

# 截图保存路径
picture_path = os.path.join(project_path, "picture")

# 登录截图保存路径
picture_login_path = os.path.join(project_path, "picture", "login")

# 用户制作-新增截图保存路径
picture_add_user_path = os.path.join(project_path, "picture", "add_user")

# mysql 配置信息
host = config_params.getValue("mysqlConfig", "host")
port = int(config_params.getValue("mysqlConfig", "port"))
user = config_params.getValue("mysqlConfig", "user")
password = config_params.getValue("mysqlConfig", "password")
